import { Map } from "immutable";
import * as actionTypes from "./instance";

const defaultState = Map({
  levelInf: [],
  vipInf: [],
});

const my = (state = defaultState, action) => {
  switch (action.type) {
    case actionTypes.USERLEVEL:
      return state.set("levelInf", action.levelInf);
    case actionTypes.USERVIP:
      return state.set("vipInf", action.vipInf);
    default:
      return state;
  }
};

export default my;
